AttachedFile

actual class AttachedFile : IAttachment

Android specific AttachedFile

Example:

AttachedFile.fromUri(
context: Context
url: Uri(path: "path/to/file"),
originalName: "file name",
mimeType: "mime/type",
fileSize: 1000
)
expect class AttachedFile : IAttachment
actual data class AttachedFile : IAttachment

Swift specific AttachedFile

Example:

AttachedFile.Companion.fromURL(
url: NSURL(path: "path/to/file"),
originalName: "file name",
mimeType: "mime/type",
fileSize: 1000
)

Types

Link copied to clipboard
actual object Companion
expect object Companion
actual object Companion

Properties

Link copied to clipboard
actual open override val fileSize: Int

File size in bytes.

expect open override val fileSize: Int

File size in bytes.

actual open override val fileSize: Int

File size in bytes.

Link copied to clipboard
actual open override val mimeType: String

Mime type of file.

expect open override val mimeType: String

Mime type of file.

actual open override val mimeType: String

Mime type of file.

Link copied to clipboard
actual open override val originalName: String

Original file name.

expect open override val originalName: String

Original file name.

actual open override val originalName: String

Original file name.

Functions

Link copied to clipboard
actual open override fun getByteArray(): ByteArray

Get the byte array of file.

expect open override fun getByteArray(): ByteArray

Get the byte array of file.

actual open override fun getByteArray(): ByteArray

Get the byte array of file.

Link copied to clipboard
actual open override fun getFilePath(): String

Get the path to file.

expect open override fun getFilePath(): String

Get the path to file.

actual open override fun getFilePath(): String

Get the path to file.